Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cassandra mock bench #1016

Merged
merged 5 commits into from
Mar 1, 2023
Merged

Cassandra mock bench #1016

merged 5 commits into from
Mar 1, 2023

Conversation

rukai
Copy link
Member

@rukai rukai commented Feb 6, 2023

cassandra_bench_mocked.rs

We want a bench that can better show small changes to performance without it getting lost in noise.

I achieved this by replacing cassandra with a custom cassandra implementation where everything is mocked out and it only supports the absolute bare minimum to perform the benchmark.
An important insight I had while working on this was that we want to assign the cores of the machine such that shotover is the bottleneck. By doing so any improvements/regression to shotover will be much more visible.

To do this I experimented with different core counts and found that giving the client and DB 3 cores and shotover 1 core made shotover sufficiently bottlenecking while allowing it to run on just an 8 core machine.
If we dont have 8 cores available then we fall back to 1 core each which is not ideal but is still better than overassigning cores on a machine that doesnt have the cores.

context of this work

I originally wrote this a while back to confirm that #985 improves performance as expected. It ended up demonstrating degraded performance so I've put 985 on hold for now, but I would still like to get this checked in for future use.

I additionally think this approach could give us more consistent results in our criterion benchmarks as I suspect the majority of the instability of results is from cassandra itself.

But for now lets just evaluate it as an --example benchmark that compares sending messages with and without shotover in between.

Copy link
Member

@benbromhead benbromhead left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fastest known protocol correct C* server known to humankind

@rukai rukai enabled auto-merge (squash) March 1, 2023 05:12
@rukai rukai merged commit a99060d into shotover:main Mar 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants